package com.liucanwen.citylist.data;

import java.util.ArrayList;
import java.util.List;

import com.csh.szhm.module.city.SzhmCityListItemBean;
import com.liucanwen.citylist.model.CityItem;
import com.liucanwen.citylist.widget.ContactItemInterface;
import com.liucanwen.citylist.widget.pinyin.PinYin;

public class CityData {

	public static List<ContactItemInterface> getSampleContactList(
			List<SzhmCityListItemBean> ls) {
		List<ContactItemInterface> list = new ArrayList<ContactItemInterface>();

		for (int i = 0; i < ls.size(); i++) {
			String cityName = ls.get(i).getName();
			list.add(new CityItem(ls.get(i).getId(), cityName, PinYin
					.getPinYin(cityName)));
		}

		return list;
	}

}
